﻿<!--#include file="../inc/common.asp" -->
<%
    if not userRightObj.canManage then
        message("您没有设置权限")
    end if
    call OpenDB
%>
<HTML><HEAD><TITLE><%=blogObj.blogTitle%>—控制面板—基本信息</TITLE>
<link rel="stylesheet" href="<%=cssFile%>" type="text/css" />
<script language=javascript>
function selectPhoto(){
    window.open("select_photo.asp","select_thoto","width=220px,height=400px,resizable,scrollbars");
}
</script>
</HEAD>
<body bgcolor="#c1c1c1" leftmargin="0" topmargin="0" style="font-size:10pt">
<div style="width:760px;height:100%;">

<div style="float:left;width: 160px; padding-top:20px">
<!--#include file="menu.asp" -->
</div>

<div style="background:#ffffff; width:580px; height:100%;float:left;padding:20px 10px 10px 10px">
<%
    if request("save")=" 保存修改 " then
        sql = " select blog_title, blog_desc,banner_Url, photo_Url, page_Size, show_content from blog where blog_id=" & blogObj.blogId
        rs.open sql, conn, 1, 3
        blogObj.blogTitle = filterHtml(request("blog_title"))
        blogObj.blogDesc = filterHtml2(request("blog_desc"),true)
        blogObj.photoUrl = filterHtml(request("photo_url"))
        blogObj.pageSize = filterHtml(request("page_size"))
        if request("show_content")="true" then
            blogObj.showContent   = true
        else    
            blogObj.showContent  = false
        end if
        rs("blog_title") = blogObj.blogTitle
        rs("blog_desc") = blogObj.blogDesc
        rs("photo_url") = blogObj.photoUrl
        rs("page_size") = blogObj.pageSize
        rs("show_content") = blogObj.showContent
        rs.update()
        rs.close()
        
        call blogObj.cache()
        
        blogCatObj.pageSize = blogObj.pageSize
        call blogCatObj.loadTotalItemCountFromDB()
        call blogCatObj.cache()
        
        dim mlHost
        set mlHost = new MLHostClass   
        call mlHost.reload()             
                
        response.write("<b>保存成功！</b>")
    end if

%><form name=form1 action=basic.asp method=post>
<input type=hidden name=blog_id value="<%=blogObj.blogId%>">
<p>标题：<input type=text name=blog_title size=60 value="<%=blogObj.blogTitle%>"> </p>
<p>介绍：<textarea name=blog_desc cols=60 rows=3 ><%=blogObj.blogDesc%></textarea> </p>
<p>图片地址：<input type=text name=photo_url size=36 value="<%=blogObj.photoUrl%>"> 
<input type=button value="选择" onclick="selectPhoto()">
图片宽度建议小于180px </p>
<p>默认是否显示文章内容：
   <input type=radio name=show_content value="true" <% if blogObj.showContent then response.write("checked") end if %> >显示 
   <input type=radio name=show_content value="false" <% if blogObj.showContent then response.write("") else response.write("checked") end if %> >不显示 
</p>
<p>每页显示文章数：<input type=text name=page_size size=4 value="<%=blogObj.pageSize%>"> 建议大于5篇少于15篇</p>
<p align=center><input type=submit name=save value=" 保存修改 "></p>
</form>
</div>

<div>
</body>    
</html>    
<!--#include file="../inc/end.asp" -->
